package com.xintonghua.bussiness.ui.fragment.client.user;

import android.app.Activity;
import android.content.Intent;
import android.os.Bundle;
import android.util.Log;
import android.view.View;
import android.widget.Button;
import android.widget.LinearLayout;

import com.xintonghua.bussiness.R;
import com.xintonghua.bussiness.base.BaseActivity;

import butterknife.BindView;
import butterknife.ButterKnife;
import butterknife.OnClick;

/**
 * Created by liqi on 2018/4/1.
 * 选择天数
 */

public class SelectTianShuActivity extends BaseActivity {

    @BindView(R.id.dialog_layout)
    LinearLayout dialogLayout;
    String tag = "SelectsSexActivity";
    @BindView(R.id.btn_three)
    Button btnThree;
    @BindView(R.id.btn_qi)
    Button btnQi;
    @BindView(R.id.btn_sanshitian)
    Button btnSanshitian;
    @BindView(R.id.baomi)
    Button baomi;
    @Override
    protected void onCreate(Bundle savedInstanceState) {
        super.onCreate(savedInstanceState);
        setContentView(R.layout.activity_selects_tianshu);
        ButterKnife.bind(this);
    }
    @OnClick({R.id.btn_three, R.id.btn_qi, R.id.btn_sanshitian, R.id.baomi, R.id.dialog_layout})
    public void onViewClicked(View view) {
        Intent intent = null;
        switch (view.getId()) {
            case R.id.btn_three:
                intent = new Intent();
                intent.putExtra("data", "3");
                setResult(Activity.RESULT_OK, intent);
                Log.i(tag, "0");
                finish();
                break;
            case R.id.btn_qi:
                intent = new Intent();
                intent.putExtra("data", "7");
                setResult(Activity.RESULT_OK, intent);
                Log.i(tag, "1");
                finish();
                break;
            case R.id.btn_sanshitian:
                intent = new Intent();
                intent.putExtra("data", "30");
                setResult(Activity.RESULT_OK, intent);
                finish();
                break;
            case R.id.baomi:
                finish();
                break;
            case R.id.dialog_layout:
                finish();
                break;
        }
    }
}